<!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="UTF-8" />
		<meta name="viewport" content="width=device-width, initial-scale=1.0" />
		<meta http-equiv="X-UA-Compatible" content="ie=edge" />
		<title>Hello</title>
	</head>

	<body>
		<img id="imgs" src="" style="width: 50px; height: 50px" alt="" />
	</body>
	<script>
		const query = window.location.search.substring(1) || ''
		const name = query.split('name=')[1]
		const avatar = query.split('&')[1].split('=')[1]
		// name=wyp0712&avatar=1.png
		console.log(avatar, 'avatar')
		imgs.src = avatar

		document.body.appendChild(
			document.createTextNode(`Welcome, ${decodeURIComponent(name)}`)
		)
	</script>
</html>
